#include<iostream>
#include<vector>
using namespace std;

class Solution {
public:
    vector<int> findPeaks(vector<int>& mountain) {
        vector<int>::iterator it = mountain.begin() + 1;
        vector<int> ans;
        ans.reserve(100);
        while (it + 1 < mountain.end()) {
            if (*it > *(it - 1) && *it > *(it + 1)) {
                ans.push_back(it - mountain.begin());
            }
            ++it;
        }
        return ans;
    }
};

